{% extends "@!SonataAdmin/Core/dashboard.html.twig" %}

{% block stylesheets %}
    {{ parent() }}

    {% if setting.obj.dashboardType == 'workbench' %}
        <link rel="stylesheet" href="{{ asset('css/backend/default/workbench.css') }}"/>
    {% endif %}
{% endblock %}

{% block javascripts %}
    {{ parent() }}

    {% if setting.obj.dashboardType == 'workbench' %}
        <script src="{{ asset('other/chartjs/Chart.min.js') }}" type="text/javascript"></script>
    {% endif %}
{% endblock %}

{% block content %}

    {% if setting.obj.dashboardType == 'classics' %}
        {{ render(controller('App\\Controller\\Backend\\DefaultController::DashboardTypeClassics')) }}
    {% elseif setting.obj.dashboardType == 'workbench' %}
        {{ render(controller('App\\Controller\\Backend\\DefaultController::DashboardTypeWorkbench')) }}
    {% else %}
        {{ render(controller('App\\Controller\\Backend\\DefaultController::DashboardTypeClassics')) }}
    {% endif %}

{% endblock %}
